home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 July: Mac OS SDK / Dev.CD Jul 99 SDK1.toast / Development Kits / Mac OS / Apple Shared Library Manager / ASLM 2.0.1 Licensing Disk / Sources / ASLMAssertionRules.r next >
Encoding:
Text File  |  1996-11-19  |  4.2 KB  |  196 lines  |  [TEXT/MPS ]

  1. /*
  2.     File:        ASLMAssertionRules.r
  3.  
  4.     Contains:    Rules to set assertions.
  5.  
  6.     Copyright:    © 1992-1994 by Apple Computer, Inc., all rights reserved.
  7.  
  8. */
  9.  
  10. /**********************************************************************
  11. ** Rules to assert errors
  12. ***********************************************************************/
  13.  
  14. resource 'inrl' (rAssertNoSystemError)
  15. {
  16.     format0
  17.     {{
  18.         addAssertion{{aNoSystemError}}
  19.     }};
  20. };
  21.  
  22. #if GENERATING68K
  23.     #if SYSTEM6
  24.         resource 'inrl' (rAssertBadSystemError)
  25.         {
  26.             format0
  27.             {{
  28.                 addAssertion{{aBadSystemError}}
  29.             }};
  30.         };
  31.  
  32.     #else
  33.         resource 'inrl' (rAssertSystem7OnlyError)
  34.         {
  35.             format0
  36.             {{
  37.                 addAssertion{{aSystem7OnlyError}}
  38.             }};
  39.         };
  40.     #endif
  41. #endif
  42.  
  43. #if GENERATINGPOWERPC && !GENERATING68K
  44.     resource 'inrl' (rAssertPowerPCOn68KError)
  45.     {
  46.         format0
  47.         {{
  48.             addAssertion{{aPowerPCOn68KError}}
  49.         }};
  50.     };
  51. #endif
  52.  
  53. /**********************************************************************
  54. ** Rule to determime of a later version of SLM is already installed
  55. ***********************************************************************/
  56.  
  57. #if GENERATING68K
  58.     resource 'inrl' (rCheckForLater68kASLM)
  59.     {
  60.         format0
  61.         {{
  62.             checkFileVersion {fsTgtSharedLibraryManager, SLMCheckVersion},
  63.             addAssertion{{aHasLater68kASLM}}
  64.         }};
  65.     };
  66. #endif
  67.  
  68. #if GENERATINGPOWERPC
  69.     resource 'inrl' (rCheckForLaterPPCASLM)
  70.     {
  71.         format0
  72.         {{
  73.             checkFileVersion {fsTgtSharedLibraryManagerPPC, SLMCheckVersion},
  74.             checkAllAssertions {{aHasSystemPPC}},
  75.             addAssertion{{aHasLaterPPCASLM}}
  76.         }};
  77.     };
  78. #endif
  79.  
  80. /**********************************************************************
  81. ** Rule to determime if EtherTalk Phase 2 is already installed.
  82. ***********************************************************************/
  83.  
  84. resource 'inrl' (rCheckForEtherTalk)
  85. {
  86.     format0
  87.     {{
  88.         checkFileVersion {fsTrgEtherTalk, 0, 0, 0, 0},
  89.         addAssertion{{aHasEtherTalk}}
  90.     }};
  91. };
  92.  
  93. resource 'inrl' (rCheckForEtherTalk2_0)
  94. {
  95.     format0
  96.     {{
  97.         checkFileVersion {fsTrgEtherTalk2_0, 0, 0, 0, 0},
  98.         addAssertion{{aHasEtherTalk}}
  99.     }};
  100. };
  101.  
  102. resource 'inrl' (rCheckForEtherTalk2_1)
  103. {
  104.     format0
  105.     {{
  106.         checkFileVersion {fsTrgEtherTalk2_1, 0, 0, 0, 0},
  107.         addAssertion{{aHasEtherTalk}}
  108.     }};
  109. };
  110.  
  111. resource 'inrl' (rCheckForEtherTalkPhase2)
  112. {
  113.     format0
  114.     {{
  115.         checkFileVersion {fsTrgEtherTalkPhase2, 0, 0, 0, 0},
  116.         addAssertion{{aHasEtherTalk}}
  117.     }};
  118. };
  119.  
  120. /**********************************************************************
  121. ** Rules to determine the System version
  122. ***********************************************************************/
  123.  
  124. /*    -----------------------------------------------------------------
  125.     Asserts 'aHasAnySystem' if any system file at all is present
  126.     ----------------------------------------------------------------- */
  127.  
  128. resource 'inrl' (rCheckForAnySystem) 
  129. {
  130.     format0
  131.     {{
  132.         checkFileVersion {fsSystemFile, 0, 0, 0, 0},
  133.         addAssertion {{aHasAnySystem}}
  134.     }};
  135. };
  136.  
  137. #if GENERATING68K
  138.  
  139.     /*    -----------------------------------------------------------------
  140.         Asserts 'aHasSystem6' if installng on System 6.0.5 or higher
  141.         ----------------------------------------------------------------- */
  142.     
  143.     resource 'inrl' (rCheckForSystem6) 
  144.     {
  145.         format0
  146.         {{
  147.             checkFileVersion {fsSystemFile, 6, 5, release, 0},
  148.             addAssertion {{aHasSystem6, aHasSystem68k}}
  149.         }};
  150.     };
  151.     
  152.     /*    -----------------------------------------------------------------
  153.         Asserts 'aHasSystem7' if installing on System 7.0 or higher
  154.         ----------------------------------------------------------------- */
  155.     
  156.     resource 'inrl' (rCheckForSystem7) 
  157.     {
  158.         format0
  159.         {{
  160.             checkFileVersion {fsSystemFile, 7, 0, release, 0},
  161.             addAssertion {{aHasSystem7, aHasSystem68k}}
  162.         }};
  163.     };
  164.     
  165.     /*    -----------------------------------------------------------------
  166.         Asserts 'aHasSystemAUX' installing on A/UX
  167.         ----------------------------------------------------------------- */
  168.     
  169.     resource 'inrl' (rCheckForSystemAUX) 
  170.     {
  171.         format0
  172.         {{
  173.             checkGestaltAttributes {'a/ux', 0xFFFFFFFF },
  174.             addAssertion {{aHasSystemAUX, aHasSystem68k}}
  175.         }};
  176.     };
  177.  
  178. #endif
  179.  
  180. #if GENERATINGPOWERPC
  181.  
  182.     /*    -----------------------------------------------------------------
  183.         Asserts 'aHasSystemPPC' installing on PowerPC
  184.         ----------------------------------------------------------------- */
  185.     
  186.     resource 'inrl' (rCheckForSystemPPC) 
  187.     {
  188.         format0
  189.         {{
  190.             checkGestalt {'sysa', { 2 } },
  191.             addAssertion {{aHasSystemPPC }}
  192.         }};
  193.     };
  194.  
  195. #endif
  196.